using Microsoft.Extensions.DependencyInjection;
using AutoMapper;

namespace ORS.OrderRobot.Service;
public static class ServiceCollectionExtensions
{
    /// <summary>
    /// 注册map映射
    /// </summary>
    /// <param name="services"></param>
    /// <returns></returns>
    public static IServiceCollection AddDtoMappers(this IServiceCollection services)
    {
        services.AddAutoMapper(cfg => {
            cfg.AddProfile<MappingProfile>();
        });
        return services;
    }
}